package cn.wolfcode.crm.service.impl;

import cn.wolfcode.crm.domain.SystemDictionaryBill;
import cn.wolfcode.crm.mapper.SystemDictionaryBillMapper;
import cn.wolfcode.crm.query.QueryForObject;
import cn.wolfcode.crm.service.ISystemDictionaryBillService;
import cn.wolfcode.crm.util.PageResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SystemDictionaryBillServiceImpl implements ISystemDictionaryBillService {
    @Autowired
    private SystemDictionaryBillMapper mapper;

    public void deleteByPrimaryKey(Long id) {
        mapper.deleteByPrimaryKey(id);
    }

    public void insert(SystemDictionaryBill record) {
        mapper.insert(record);

    }

    public SystemDictionaryBill selectByPrimaryKey(Long id) {
        return mapper.selectByPrimaryKey(id);
    }

    public List<SystemDictionaryBill> selectAll() {
        return mapper.selectAll();
    }

    public void updateByPrimaryKey(SystemDictionaryBill record) {
        mapper.updateByPrimaryKey(record);
    }

    public PageResult query(QueryForObject qo) {
        return null;
    }

    /*public PageResult query(QueryForObject qo) {
        int total = mapper.queryForCount(qo);

        if (total == 0) {
            return new PageResult();
        }

        List<SystemDictionaryBill> rows = mapper.queryForList(qo);

        return new PageResult(total, rows);
    }

    public List<SystemDictionaryBillBill> queryDictionaryBillByParentId(Long pId) {
        return BillMapper.queryDictionaryBillByParentId(pId);
    }*/
}
